home *** CD-ROM | disk | FTP | other *** search
/ Softwarová Záchrana 3 / Softwarova-zachrana-3.bin / Xteq X-Setup / xqdcXSP-Setup-EN.exe / {app} / plugins / XQ MSOXP User Places 1 Sort.xpl < prev    next >
Text File  |  2004-01-29  |  2KB  |  77 lines

  1. "FILE"="Xteq Systems X-Setup Plugin 5.0"
  2. "TYPE"="7"
  3. "COUNT"="5"
  4. "UIPATH"="Program Options\Microsoft Office\MS Office XP\Open/Save Dialog\User Defined Place 1"
  5. "NAME"="Sort Order"
  6. "VERSION"="1.10"
  7. "LANGUAGE"="VBScript"
  8. "TEXT 1"="(Default)"
  9. "TEXT 2"="Sort by Name"
  10. "TEXT 3"="Sort by Type"
  11. "TEXT 4"="Sort by Size"
  12. "TEXT 5"="Sort by Date"
  13. "DESCRIPTION 1"="If you wish a different sort order for your user defined place, you can simply configure it here."
  14. "DESCRIPTION 2"="Please note that this setting will only be applied to the folder of the user defined place itself. If you change to a subfolder of that folder, Office will apply the default sort order again."
  15. "AUTHOR"="Xteq Systems"
  16. "CONTACTURL"="http://www.xteq.com/"
  17. "COPYRIGHT"="Copyright ⌐ Xteq Systems - All Rights Reserved"
  18. "COMMENT 1"="Found here: http://www.frontpages-web-hosting.net/support/frontpage.2003.how.to.826214.htm"
  19.  
  20.  
  21. '!!!! MAIN FILE (XQ MSOxxx User Places 1 xxx.xpl) !!!!
  22.  
  23.  
  24. sPlaceNameID=1
  25. sPCheck="HKCU\Software\Microsoft\Office\10.0\"
  26. sV1=sPCheck & "Common\Open Find\Places\UserDefinedPlaces\Place" & sPlaceNameID & "\ArrangeBy"
  27. ' 1=Name, 2=Type, 3=Size, 4=Date
  28.  
  29.  
  30. Sub Plugin_Initialize 
  31. if RegPathExists(sPCheck) then
  32.    i=RegReadValue(sV1)
  33.  
  34.    if IsEmpty(i)=true or i=0 then setuielement 1,true
  35.  
  36.    if i=1 then setuielement 2,true
  37.    if i=2 then setuielement 3,true
  38.    if i=3 then setuielement 4,true
  39.    if i=4 then setuielement 5,true
  40. else
  41.    Call Disable()
  42. end if
  43. End Sub
  44.  
  45. Sub Plugin_CheckData(ElementIndex)
  46. End Sub
  47.  
  48. Sub Plugin_Apply(ElementIndex,ElementSubIndex)
  49.  if GetUIElement(1)=true then
  50.     v=0
  51.  else
  52.     if GetUIElement(2)=true then
  53.        v=1
  54.     else
  55.        if GetUIElement(3)=true then
  56.           v=2
  57.        else
  58.           if GetUIElement(4)=true then
  59.              v=3
  60.           else
  61.              v=4
  62.           end if
  63.        end if
  64.     end if
  65.  end if
  66.  
  67.  
  68.  if v>0 then 
  69.     Call RegWriteValue(sV1,v,2)
  70.  else 
  71.     if RegValueExists(sV1) then Call RegDeleteValue(sV1)
  72.  end if
  73. End Sub
  74.  
  75. Sub Plugin_Terminate 
  76. End Sub
  77.